package com.design.cjm.behavioral.Iterator.example;

/**
 * @Author: Jie Ming Chen
 * @Date: 2018/9/24
 * @Version 1.0
 */
public class ConcreteIterator extends Iterator{

    private ConcreteAggregate aggregate;

    private int current = 0;

    public ConcreteIterator(ConcreteAggregate aggregate) {

        this.aggregate = aggregate;
    }

    @Override
    public Object first() {
        return aggregate;
    }

    @Override
    public Object next() {

        Object ret = null;
        current++;

        return null;
    }

    @Override
    public boolean isDone() {
        return false;
    }

    @Override
    public Object currentItem() {
        return null;
    }
}
